///////////////////////////////////////////////////////////////////////////////
//
// Licensed under the MIT License
//
// Copyright (c) 2010 Chris Colinsky
// All Rights Reserved
//
// version	0.5
// http://code.google.com/p/sugarcookie/
// http://code.google.com/p/sugarcookie/wiki/License
//
////////////////////////////////////////////////////////////////////////////////

package sugarcookie.error {
	import mx.logging.Log;
	import mx.logging.ILogger;
	
	/**
	 * Extends the Error class to provide output to the logger.
	 */
	public class ApplicationError extends Error {
		private var _log:ILogger;
		
		public function ApplicationError(message:String="", id:int=0) {
			super(message, id);
			_log = Log.getLogger("sugarcookie.error.ApplicationError");
			_log.error(getStackTrace());
		}
	}
}